/*
 *  Licensed to the Apache Software Foundation (ASF) under one
 *  or more contributor license agreements.  See the NOTICE file
 *  distributed with this work for additional information
 *  regarding copyright ownership.  The ASF licenses this file
 *  to you under the Apache License, Version 2.0 (the
 *  "License"); you may not use this file except in compliance
 *  with the License.  You may obtain a copy of the License at
 *
 *        http://www.apache.org/licenses/LICENSE-2.0
 *
 *  Unless required by applicable law or agreed to in writing,
 *  software distributed under the License is distributed on an
 *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 *  KIND, either express or implied.  See the License for the
 *  specific language governing permissions and limitations
 *  under the License.
 */

package org.apache.isis.viewer.dnd.drawing;

public interface Canvas {
    Canvas createSubcanvas();

    Canvas createSubcanvas(Bounds bounds);

    Canvas createSubcanvas(int x, int y, int width, int height);

    void draw3DRectangle(int x, int y, int width, int height, Color color, boolean raised);

    void drawDebugOutline(Bounds bounds, int baseline, Color color);

    void drawImage(Image image, int x, int y);

    void drawImage(Image image, int x, int y, int width, int height);

    void drawLine(int x, int y, int x2, int y2, Color color);

    void drawLine(Location start, int xExtent, int yExtent, Color color);

    void drawOval(int x, int y, int width, int height, Color color);

    void drawRectangle(int x, int y, int width, int height, Color color);

    void drawRectangleAround(Bounds bounds, Color color);

    void drawRoundedRectangle(int x, int y, int width, int height, int arcWidth, int arcHeight, Color color);

    void drawShape(Shape shape, Color color);

    void drawShape(Shape shape, int x, int y, Color color);

    void drawSolidOval(int x, int y, int width, int height, Color color);

    void drawSolidRectangle(int x, int y, int width, int height, Color color);

    void drawSolidShape(Shape shape, Color color);

    void drawSolidShape(Shape shape, int x, int y, Color color);

    void drawText(String text, int x, int y, Color color, Text style);

    void drawText(String text, int x, int y, int maxWidth, Color color, Text style);

    void offset(int x, int y);

    boolean overlaps(Bounds bounds);
}
